#Include <ScreenCapture.au3>
#Include <Function For Print.au3>

Common_WriteCurrentFunctionNameToTempTXT($sPrintFunctionName)

Dim $bDebug = False

If Not $bDebug Then
	
	Print3_1_1()
	Print3_1_2()
	Print3_1_3()
	Print3_1_4()
	Print3_2_1()
	Print3_2_2()
	Print3_3_1()
	Print3_3_2()
	Print3_4_1()
	Print3_4_2()
	Print3_4_3()
	Print3_5_2()
	Print3_5_3()
	Print3_5_4()
	Print3_5_6()
	Print3_5_7()
	Print3_5_8()
	Print3_6_2()
	Print3_6_3()
	Print3_6_4()
	Print3_6_7()
	Print3_6_8()
	Print3_7_1()
	Print3_7_2()
	Print3_8_1()
	Print3_8_2()
	Print3_10_1()
	Print3_10_2()
	Print3_10_3()
	Print3_10_4()
	Print3_14_1()
	Print3_14_2()
	Print3_16_1()
	Print3_18_1()
	Print3_18_2()
	Print3_18_3()
	Print3_18_4()
	Print3_18_5()
	Print3_18_6()
	Print3_18_7()
	Print3_18_8()
	Print3_18_10()
	Print3_18_11()
	Print3_18_12()
	Print3_18_131415()
	Print3_18_17()
	Print3_19_1()
	Print3_19_2()
	Print3_21_1()
	Print3_22_1()
	Print3_23_1()
	Print3_23_2()
	Print3_23_3()
	Print3_23_4()
	Print3_24_1()
	Print3_24_2()
	Print3_24_3()
	Print3_24_4()
	Print3_7_3()
	Print3_7_4()
EndIf


CloseOpenedExcel($oExcel)


Func Print3_1_1()
	Local $TestCaseID = "3.1.1"
	$sCusMsg = ''
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	OpenProperties()
	Common_ScreenCaprureWindow($sTestResultPath,$sCaptureImage, WinGetHandle(''))
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage)  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_1_2()
	Local $TestCaseID = "3.1.2"
	$sCusMsg = 'The image is print dialog'
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	OpenProperties()
	ControlClick($CommonWindowCtrlInfro,"",14009)
	Common_SleepTime(4) 	
	Common_ScreenCaprureWindow($sTestResultPath,$sCaptureImage, WinGetHandle(''))
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage)  			
	If $bCompareFile Then	
		Send('{ESC}')
		Send('{ESC}')
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Send('{ESC}')
	Send('{ESC}')
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_1_3()
	Local $TestCaseID = "3.1.3"
	$sCusMsg = 'The image is printer Properties window'
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	OpenProperties()
	ControlClick($CommonWindowCtrlInfro,"",14009)
	Common_SleepTime(4) 	
	ControlClick($CommonWindowCtrlInfro,"",1025)
	Common_SleepTime(4)
	Common_ScreenCaprureWindow($sTestResultPath,$sCaptureImage, WinGetHandle(''))	
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage)  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_1_4()
	Local $TestCaseID = "3.1.4"
	$sCusMsg = ''
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	Local $posPMWindow = WinGetPos($hPMHandle)
	MouseClick('right',$posPMWindow[0]+120,$posPMWindow[1]+$posPMWindow[3]-40)
	Common_SleepTime(1)	
	Send('{DOWN}')
	Sleep(300)
	Send('{ENTER}')
	Common_SleepTime(4) 
	Common_ScreenCaprureWindow($sTestResultPath,$sCaptureImage, WinGetHandle(''))
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage)  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_2_1()
	Local $TestCaseID = "3.2.1"
	$sCusMsg = ''
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '2.avi', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	SelectPrint()
	Common_ScreenCaprureWindow($sTestResultPath,$sCaptureImage, WinGetHandle(''))
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage)  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_2_2()
	Local $TestCaseID = "3.2.2"
	$sCusMsg = ''
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '2.avi', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	SelectPrint()
	Send('{Enter}')
	Send('{ESC}')
	Common_SleepTime(2)	
	If WinGetHandle('Presto! PageManager', 'OK') == '' Then
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_3_1()
	Local $TestCaseID = "3.3.1"
	$sCusMsg = ''
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '2.avi', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)
	SelectPrint()
	Common_ScreenCaprureWindow($sTestResultPath,$sCaptureImage, WinGetHandle(''))
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage)  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_3_2()
	Local $TestCaseID = "3.3.2"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '2.avi', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)
	SelectPrint()
	Send('{ESC}')
	Common_SleepTime(5)
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_4_1()
	Local $TestCaseID = "3.4.1"
	$sCusMsg = 'The image is Print window'
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	OpenProperties()
	ControlCommand($CommonWindowCtrlInfro,"",14015,"Check", "")
	Common_SleepTime(2)
	ControlClick($CommonWindowCtrlInfro,"",1)	
	Common_SleepTime(1)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	SelectPrint()
	Common_ScreenCaprureWindow($sTestResultPath,$sCaptureImage, WinGetHandle(''))
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage)  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_4_2()
	Local $TestCaseID = "3.4.2"
	$sCusMsg = ''
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	OpenProperties()
	ControlCommand($CommonWindowCtrlInfro,"",14015,"Check", "")
	Common_SleepTime(2)
	ControlClick($CommonWindowCtrlInfro,"",1)	
	Common_SleepTime(1)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	SelectPrint()
	ControlClick("Print","","Button11")   ;clicke "Cancel" button in print setting window. If use button ID to identifier, conrtrolClick will fail.
	Common_SleepTime(2)
	Local $statePrintSettingDialog = WinGetState("Print")			;16 = Window is minimized (becase the window is not closed so not used WinExist)
	If WinGetHandle("Print") = "" Then
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile& $sFailLogMsg, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_4_3()
	Local $TestCaseID = "3.4.3"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	OpenProperties()
	ControlCommand($CommonWindowCtrlInfro,"",14015,"Check", "")
	Common_SleepTime(2)
	ControlClick($CommonWindowCtrlInfro,"",1)	
	Common_SleepTime(1)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	SelectPrint()
	Send('{ENter}')
	Common_SleepTime(5)
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_5_2()
	Local $TestCaseID = "3.5.2"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '3.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)	
	OpenProperties()
	OrininalSize()
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_5_3()
	Local $TestCaseID = "3.5.3"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '3.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)	
	OpenProperties()
	OrininalSize()
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_5_4()
	Local $TestCaseID = "3.5.4"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'DOC.doc', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(20)
	WinActivate($hPMHandle)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	OpenProperties()
	OrininalSize()
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_5_6()
	Local $TestCaseID = "3.5.6"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '3.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)	
	OpenProperties()
	PrintSetting('Fit to Page')
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_5_7()
	Local $TestCaseID = "3.5.7"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '3.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)	
	OpenProperties()
	PrintSetting('Fit to Page')
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_5_8()
	Local $TestCaseID = "3.5.8"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'DOC.doc', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(20)
	WinActivate($hPMHandle)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	OpenProperties()
	PrintSetting('Fit to Page')
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_6_2()
	Local $TestCaseID = "3.6.2"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '3.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)	
	OpenProperties()
	PrintSetting('Halftone Image')
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_6_3()
	Local $TestCaseID = "3.6.3"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '3.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)	
	OpenProperties()
	PrintSetting('Halftone Image')
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_6_4()
	Local $TestCaseID = "3.6.4"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'DOC.doc', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(20)
	WinActivate($hPMHandle)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	OpenProperties()
	PrintSetting('Halftone Image')
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_6_6()
	Local $TestCaseID = "3.6.6"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '3.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)	
	OpenProperties()
	PrintSetting('Diffuse')
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_6_7()
	Local $TestCaseID = "3.6.7"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '3.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)	
	OpenProperties()
	PrintSetting('Diffuse')
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_6_8()
	Local $TestCaseID = "3.6.8"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'DOC.doc', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(20)
	WinActivate($hPMHandle)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	OpenProperties()
	PrintSetting('Diffuse')
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_7_1()
	Local $TestCaseID = "3.7.1"
	$sCusMsg = ''
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '3.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)	
	OpenProperties()
	ControlClick($sApplication_Properties,"",$sSetup_Button)
	Common_SleepTime(2)
	Common_ScreenCaprureWindow($sTestResultPath , $sCaptureImage,$sPrint_Dialog_Title)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage)  			
	If $bCompareFile Then	
		Send('{ESC}')
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Send('{ESC}')
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_7_2()
	Local $TestCaseID = "3.7.2"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '3.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)	
	OpenProperties()
	Send("{Enter}")
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_7_3()
	Local $TestCaseID = "3.7.3"
	$sCusMsg = ''
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	ControlClick($hPMHandle, "", $sPageViewButtonInToolbarCtrInfo)
	Common_SleepTime(8)	
	If $bPageViewType	Then	
		OpenProperties()
	Else
		OpenProperties()
	EndIf
	ControlClick($sApplication_Properties,"",$sSetup_Button)
	Common_SleepTime(2)
	If Not WinWaitActive($sPrint_Dialog_Title, "", 5) Then
		Common_SleepTime(1)
		Common_WriteLog($sFaile& $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 0
	EndIf
	Common_ScreenCaprureWindow($sTestResultPath ,$sCaptureImage,WinGetHandle(""))
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage) 
	If $bCompareFile Then	
		Send('{ESC}')
		Send('{ESC}')
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile& $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)    
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_7_4()
	Local $TestCaseID = "3.7.4"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	ControlClick($hPMHandle, "", $sPageViewButtonInToolbarCtrInfo)
	Common_SleepTime(8)
	If $bPageViewType	Then	
		Send("^p")
	Else
		SelectPrint()
	EndIf
	Common_SleepTime(3)
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_8_1()
	Local $TestCaseID = "3.8.1"
	$sCusMsg = ''
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	OpenProperties()
	ControlClick($CommonWindowCtrlInfro,"",14009)   ;Setup 
	Common_SleepTime(4) 	
	ControlSetText($CommonWindowCtrlInfro,"",1154, "0")   ;Number of copies.
	Common_SleepTime(1)
	Send("{Enter}")
	Common_SleepTime(2)
	Common_ScreenCaprureWindow($sTestResultPath,$sCaptureImage, WinGetHandle(''))
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage)  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_8_2()
	Local $TestCaseID = "3.8.2"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	OpenProperties()
	ControlClick($CommonWindowCtrlInfro,"",14009)   ;Setup 
	Common_SleepTime(4) 	
	ControlSetText($CommonWindowCtrlInfro,"",1154, "1")   ;Number of copies.
	Common_SleepTime(1)
	Send("{Enter}")
	Common_SleepTime(1)
	ControlClick($CommonWindowCtrlInfro,"",1)
	Common_SleepTime(1)
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_10_1()
	Local $TestCaseID = "3.10.1"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '3.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)		
	OpenProperties()
	SetPaperSize("Letter")
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_10_2()
	Local $TestCaseID = "3.10.2"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '3.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)		
	OpenProperties()
	SetPaperSize("Legal")
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_10_3()
	Local $TestCaseID = "3.10.3"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '3.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)		
	OpenProperties()
	SetPaperSize("A4")
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_10_4()
	Local $TestCaseID = "3.10.4"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '3.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)		
	OpenProperties()
	SetPaperSize("A5")
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_14_1()
	Local $TestCaseID = "3.14.1"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '3.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)		
	OpenProperties()
	SetOrientation("Portrait")
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_14_2()
	Local $TestCaseID = "3.14.2"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '3.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)		
	OpenProperties()
	SetOrientation("Landscape")
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_16_1()
	Local $TestCaseID = "3.16.1"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '3.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)
	Common_SleepTime(1)		
	ControlClick($hPMHandle, "", $sStackButtonInToolbarCtrInfo)
	Common_SleepTime(2)	
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_17_1()
	Local $TestCaseID = "3.17.1"
	$sCusMsg = ''
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	ControlClick($hPMHandle, "", $sPageViewButtonInToolbarCtrInfo)   ;Click page view button.
	Common_SleepTime(6)	
	Common_AddAnnotation()
	;SelectPrint()
	Send("^p")   ;Send ctrl + P to print.
	If WinExists($sMessageTitle) Then
		Local $textMessage = ControlGetText($sMessageTitle,"",65535)
		If $textMessage="The edited files have annotations. Do you want to save the annoations with the image or text?" Then	
			Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
			Common_Close_PM($hPMHandle) 
			Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
			Return 1  
		Else
			Common_WriteLog($sFaile&$sFailLogMsg, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
			Common_Close_PM($hPMHandle) 
			Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
			Return 0  
		EndIf
	EndIf
	Common_WriteLog($sFaile &$sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0  
EndFunc

Func Print3_17_2()
	Local $TestCaseID = "3.17.2"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	ControlClick($hPMHandle, "", $sPageViewButtonInToolbarCtrInfo)   ;Click page view button.
	Common_SleepTime(6)	
	AddAnnotation($hPMHandle)
	SelectPrint()
	ControlClick($sMessageTitle,'',7)   ;No button.
	Common_SleepTime(2)	
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_17_3()
	Local $TestCaseID = "3.17.3" 
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	ControlClick($hPMHandle, "", $sPageViewButtonInToolbarCtrInfo)   ;Click page view button.
	Common_SleepTime(6)	
	AddAnnotation($hPMHandle)
	SelectPrint()
	ControlClick('','',6)   ;Yes button.
	Common_SleepTime(2)	
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_17_4()
	Local $TestCaseID = "3.17.4"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	ControlClick($hPMHandle, "", $sPageViewButtonInToolbarCtrInfo)   ;Click page view button.
	Common_SleepTime(6)	
	MouseClick('left',304,947)
	Common_SleepTime(2)	
	AddAnnotation($hPMHandle)
	SelectPrint()
	ControlClick('','',6)   ;Yes button.
	Common_SleepTime(2)	
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_17_5()
	Local $TestCaseID = "3.17.5"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'DOC.doc', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(20)	
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	ControlClick($hPMHandle, "", $sPageViewButtonInToolbarCtrInfo)   ;Click page view button.
	Common_SleepTime(16)	
	
	;Add annotation in doc
	MouseClick('left',1254,134)
	Common_SleepTime(1)
	MouseClick('left',1254,257)
	Common_SleepTime(1)
	ControlClick($hPMHandle, "", $sSwicthToThumbnailViewButtonCtrInfo)   ;Click thumbnail button.
	Send('{ENTER}')   ;Save anonotaton.		
	Common_SleepTime(2)	
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_17_6()
	Local $TestCaseID = "3.17.6"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'pssword is 123.PDF', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(10)	
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	ControlClick($hPMHandle, "", $sPageViewButtonInToolbarCtrInfo)   ;Click page view button.
	Common_SleepTime(8)	
	Send('123')   ;Password
	Common_SleepTime(1)	
	Send('{ENTER}')
	Common_SleepTime(8)
	
	;Add annotation in doc
	MouseClick('left',1254,191)
	MouseMove(340,277)
	MouseDown('left')
	MouseMove(810,593)
	MouseUp('left')
	Common_SleepTime(1)
	ControlClick($hPMHandle, "", $sSwicthToThumbnailViewButtonCtrInfo)   ;Click thumbnail button.
	Send('{ENTER}')   ;Save anonotaton.		
	Common_SleepTime(2)	
	SelectPrint()
	ControlClick('','',6)   ;Yes button.
	Common_SleepTime(2)		
	PrintFile($sTestResultPath & $TestCaseID)
	Send('123')   ;Password
	Common_SleepTime(2)
	ControlClick('','','Button1')
	Common_SleepTime(20)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_18_1()
	Local $TestCaseID = "3.18.1" 
	$sCusMsg = 'The image is Password winodw'
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'Open Password 123.PDF', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(10)	
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	SelectPrint()	
	If WinExists('Save As', 'FolderView') Then
		PrintFile($sTestResultPath & $TestCaseID)
		Common_SleepTime(2)	
	EndIf
	Common_ScreenCaprureWindow($sTestResultPath,$sCaptureImage, WinGetHandle(''))
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage)  			
	If $bCompareFile Then	
		Send('{ESC}')
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Send('{ESC}')
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
EndFunc

Func Print3_18_2()
	Local $TestCaseID = "3.18.2"
	$sCusMsg = 'The image is protect file thumbnial'
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'Open Password 123.PDF', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(10)	
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Send('{ESC}')
	Common_ScreenCaprureWindow($sTestResultPath,$sCaptureImage, $hThumbnailView)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage)  			
	If $bCompareFile Then	
		Send('{ESC}')
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Send('{ESC}')
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
EndFunc

Func Print3_18_3()
	Local $TestCaseID = "3.18.3"
	$sCusMsg = ''
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'Open Password 123.PDF', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(10)	
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Send('11')
	Common_SleepTime(1)	
	Send('{ENTER}') 
	Common_SleepTime(2)	
	Common_ScreenCaprureWindow($sTestResultPath,$sCaptureImage, WinGetHandle(''))
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage)  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
EndFunc

Func Print3_18_4()
	Local $TestCaseID = "3.18.4" 
	$sCusMsg = 'The image is password winodw'
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'Open Password 123.PDF', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(10)	
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Send('11')
	Common_SleepTime(1)	
	Send('{ENTER}') 
	Common_SleepTime(1)	
	Send('{ENTER}') 
	Common_SleepTime(2)
	Send('11')
	Common_SleepTime(1)	
	Send('{ENTER}') 
	Common_SleepTime(1)	
	Send('{ENTER}') 
	Common_SleepTime(2)
	Send('11')
	Common_SleepTime(1)	
	Send('{ENTER}') 
	Common_SleepTime(1)	
	Send('{ENTER}') 
	Common_SleepTime(2)	
	Common_ScreenCaprureWindow($sTestResultPath,$sCaptureImage, WinGetHandle(''))
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage)  			
	If $bCompareFile Then	
		Send('{ESC}')
		Send('{ESC}')
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Send('{ESC}')
	Send('{ESC}')
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
EndFunc

Func Print3_18_5()
	Local $TestCaseID = "3.18.5"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'Open Password 123.PDF', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(10)	
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	SelectPrint()
	If WinExists ('Save As', 'FolderView' ) Then
		PrintFile($sTestResultPath & $TestCaseID)
		Sleep(2000)
		Send('123')   ;Password
		Common_SleepTime(2)
		ControlClick('','','Button1')
	Else
		Send('123')   ;Password
		Common_SleepTime(2)
		ControlClick('','','Button1')
		PrintFile($sTestResultPath & $TestCaseID)
	EndIf
	Common_SleepTime(20)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_18_6()
	Local $TestCaseID = "3.18.6"
	$sCusMsg = 'The image is password window'
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'Print Password 123.PDF', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(10)	
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	SelectPrint()	
	PrintFile($sTestResultPath & $TestCaseID)
	Common_ScreenCaprureWindow($sTestResultPath,$sCaptureImage, WinGetHandle(''))
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage)  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
EndFunc

Func Print3_18_7()
	Local $TestCaseID = "3.18.7" 
	$sCusMsg = ''
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'Print Password 123.PDF', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(10)	
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Send('11')
	Common_SleepTime(1)	
	Send('{ENTER}') 
	Common_SleepTime(2)	
	Common_ScreenCaprureWindow($sTestResultPath,$sCaptureImage, WinGetHandle(''))
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage)  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
EndFunc

Func Print3_18_8()
	Local $TestCaseID = "3.18.8" 
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'Print Password 123.PDF', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(10)	
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Send('123')   ;Password
	Common_SleepTime(2)
	ControlClick('','','Button1')
	Common_SleepTime(20)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_18_10()
	Local $TestCaseID = "3.18.10"
	$sCusMsg = ''
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'Open123Print456.PDF', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(10)	
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Send('123')   ;Open	
	Common_SleepTime(1)	
	Send('{ENTER}') 
	Common_SleepTime(2)	
	Send('123')   ;Print
	Common_SleepTime(1)	
	Send('{ENTER}') 
	Common_SleepTime(2)
	Common_ScreenCaprureWindow($sTestResultPath,$sCaptureImage, WinGetHandle(''))
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage)  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
EndFunc

Func Print3_18_11()
	Local $TestCaseID = "3.18.11" 
	$sCusMsg = ''
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'Open123Print456.PDF', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(10)	
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Send('aasssaa')   ;Open	
	Common_SleepTime(1)	
	Send('{ENTER}') 
	Common_SleepTime(2)	
	Common_ScreenCaprureWindow($sTestResultPath,$sCaptureImage, WinGetHandle(''))
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage)  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
EndFunc

Func Print3_18_12()
	Local $TestCaseID = "3.18.12" 
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'Open123Print456.PDF', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(10)	
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	SelectPrint()
	If WinExists ('Save As', 'FolderView' ) Then
		PrintFile($sTestResultPath & $TestCaseID)
		Sleep(2000)
		Send('123')   ;Open	
		Common_SleepTime(1)	
		Send('{ENTER}') 
		Common_SleepTime(2)	
		Common_SleepTime(2)
		Send('456')   ;Print
		Common_SleepTime(1)	
		Send('{ENTER}') 
		Common_SleepTime(20)
		
	Else
		Send('123')   ;Open	
		Common_SleepTime(1)	
		Send('{ENTER}') 
		Common_SleepTime(2)	
		PrintFile($sTestResultPath & $TestCaseID)
		Common_SleepTime(2)
		Send('456')   ;Print
		Common_SleepTime(1)	
		Send('{ENTER}') 
		Common_SleepTime(20)
	EndIf
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_18_131415()
	Local $a1[3] = ["3.18.13","3.18.14","3.18.15"] 
	Local $a2[3] = ["3.0","5.0","7.0"] 
	For $i = 0 to 2
		Local $TestCaseID = $a1[$i] 
		
		Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
		If $bReproduceTestCase = False Then
			Return 3   
		EndIf
		Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
		Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
		If $bExecuteTestCase = False Then
			Return 2   
		EndIf 
		Local $sCaptureImage = $TestCaseID & '.jpg'  
		Common_Del_DB() 
		Common_InitializeStatus()   
		InitializeStatusForPrint()
		FileCopy($sSampleFolderPath & $a2[$i] & '.PDF', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
		Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
		Common_SleepTime(10)	
		Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
		_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
		Common_SleepTime(1)		
		SelectPrint()
		If WinExists ('Save As', 'FolderView' ) Then
			PrintFile($sTestResultPath & $TestCaseID)
			Sleep(2000)
			Send('123')   ;Password
			Common_SleepTime(2)
			ControlClick('','','Button1')
			Common_SleepTime(20)
		Else
			Send('123')   ;Password
			Common_SleepTime(2)
			ControlClick('','','Button1')
			Common_SleepTime(2)
			PrintFile($sTestResultPath & $TestCaseID)
			Common_SleepTime(20)
		EndIf
		Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
		If $bCompareFile Then	
			Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
			Common_Close_PM($hPMHandle) 
			Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID) 
		Else
			Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
			Common_Close_PM($hPMHandle) 
			Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		EndIf
		
	Next
EndFunc

Func Print3_18_17()
	Local $TestCaseID = "3.18.17" 
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'Open Password 123.PDF', $sFunctionFolderPath, 1)
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(10)	
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	ControlListView($hPMHandle, "", $sThumbnailViewCtrInfo, "Select" ,1)	
	Common_SleepTime(1)		
	SelectPrint()
	Send('123')   ;Password
	Common_SleepTime(2)
	ControlClick('','','Button1')
	Common_SleepTime(2)
	PrintFile($sTestResultPath & $TestCaseID)
	Common_SleepTime(25)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_19_1()
	Local $TestCaseID = "3.19.1"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "right") 
	Common_SleepTime(1)	
	Send('p')
	Common_SleepTime(1)	
	Send('{right}')
	Common_SleepTime(1)	
	Send('{down}')
	Send('{down}')
	Common_SleepTime(1)	
	Send('{enter}')
	Common_SleepTime(12)	
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_19_2()
	Local $TestCaseID = "3.19.2" 
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	MouseClick('left',1268, 946)    ;Open document pallet.
	Common_SleepTime(2)	
	MouseMove(281, 170)
	MouseDown("left")
	Sleep(300)
	MouseMove(282, 879)
	Sleep(300)
	MouseUp("left")
	Common_SleepTime(2)	
	MouseClick('right',230, 870)
	Common_SleepTime(2)	
	Send('p')
	Common_SleepTime(1)	
	Send('{down}')
	Sleep(200)
	Send('{down}')
	Common_SleepTime(1)	
	Send('{enter}')
	Common_SleepTime(12)	
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_19_3()
	Local $TestCaseID = "3.19.3"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	MouseMove(281, 170)
	MouseDown("left")
	Sleep(300)
	MouseMove(115, 990)
	Sleep(300)
	MouseUp("left")
	Common_SleepTime(18)	
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_21_1()
	Local $TestCaseID = "3.21.1" 
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(10)	
	ControlClick($hPMHandle, "", $sSwicthToListViewButtonCtrInfo)
	Common_SleepTime(2)		
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Common_SleepTime(5)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_22_1()
	Local $TestCaseID = "3.22.1"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '1.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(10)	
	ControlClick($hPMHandle, "", $sTileButtonInToolBarCtrlInfo)
	Common_SleepTime(2)		
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)		
	SelectPrint()
	PrintFile($sTestResultPath & $TestCaseID)
	Common_SleepTime(5)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_23_1()
	Local $TestCaseID = "3.23.1" 
	$sCusMsg = ''
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'OCR.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(5)	
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left")
	Common_SleepTime(1)
	ControlClick($hPMHandle, "", $sOCRButtonInToolbarCtrInfo)
	Common_SleepTime(55)	
	SelectPrint()
	Common_ScreenCaprureWindow($sTestResultPath,$sCaptureImage, WinGetHandle(''))
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $sCaptureImage, $sCorrectResultPath & $sCaptureImage)  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
EndFunc

Func Print3_23_2()
	Local $TestCaseID = "3.23.2"
	$sCusMsg = ''
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'OCR.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(5)	
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left")
	Common_SleepTime(1)
	ControlClick($hPMHandle, "", $sOCRButtonInToolbarCtrInfo)
	Common_SleepTime(55)	
	If $bPageViewType	Then
		Send("^p")   ;Send ctrl + p to print.
	Else
		SelectPrint() 
	EndIf
	Common_SleepTime(5)
	If WinExists ("[CLASS:#32770]", 'OK')  Then
		Send("{ESC}")
		Sleep(1000)
	EndIf
	Send("{ESC}")
	Common_SleepTime(2)
	Send("{ESC}")
	Common_SleepTime(2)
	Local $PrintDialog = WinGetHandle("Save As")
	If $PrintDialog = "" Then
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile &$sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_23_3()
	Local $TestCaseID = "3.23.3" 
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'OCR.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(5)	
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left")
	Common_SleepTime(1)
	ControlClick($hPMHandle, "", $sOCRButtonInToolbarCtrInfo)
	Common_SleepTime(55)	
	If $bPageViewType	Then
		Send("^p")   ;Send ctrl + p to print.
	Else
		SelectPrint() 
	EndIf
	Common_SleepTime(3)
	Send('{Enter}')
	Common_SleepTime(5)
	PrintFile($sTestResultPath & $TestCaseID)
	Common_SleepTime(5)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_23_4()
	Local $TestCaseID = "3.23.4"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'OCR.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Common_SleepTime(5)	
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left")
	Common_SleepTime(1)
	ControlClick($hPMHandle, "", $sOCRButtonInToolbarCtrInfo)
	Common_SleepTime(55)	
	If $bPageViewType	Then
		Send("^p")   ;Send ctrl + p to print.
	Else
		SelectPrint() 
	EndIf
	Common_SleepTime(3)
	Send('{Enter}')
	Common_SleepTime(4)
	ControlCommand ("Presto! PageViewer","",1014,"Check", "")		;check on :Don't show this message in the future.
	Common_SleepTime()
	ControlClick ("Presto! PageViewer","",1)
	Common_SleepTime(2)
	PrintFile($sTestResultPath & $TestCaseID)
	Common_SleepTime(5)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif') 
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile& $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0
EndFunc

Func Print3_24_1()
	Local $TestCaseID = "3.24.1"
	$sCusMsg =$msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '4.tif', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	ControlClick($hPMHandle, "", $sPageViewButtonInToolbarCtrInfo)
	Common_SleepTime(10)
	If $bPageViewType	Then
		Send("^p")   ;Send ctrl + p to print.
	Else
		SelectPrint() 
	EndIf
	Common_SleepTime(2)
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_24_2()
	Local $TestCaseID = "3.24.2" 
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'mul.pdf', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	ControlClick($hPMHandle, "", $sPageViewButtonInToolbarCtrInfo)
	Common_SleepTime(10)	
	If $bPageViewType	Then
		Send("^p")   ;Send ctrl + p to print.
	Else
		SelectPrint() 
	EndIf
	Common_SleepTime(2)
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_24_3()
	Local $TestCaseID = "3.24.3"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & 'DOC.doc', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(22)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	ControlClick($hPMHandle, "", $sPageViewButtonInToolbarCtrInfo)
	Common_SleepTime(20)	
	If $bPageViewType	Then
		Send("^p")   ;Send ctrl + p to print.
	Else
		SelectPrint() 
	EndIf
	Common_SleepTime(2)
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc

Func Print3_24_4()
	Local $TestCaseID = "3.24.4"
	$sCusMsg = $msg
	$sFailLogMsg = Common_GetTestStepInSTD($sExcelSheetName,$iCurrentSheetTotalLineNumber,$TestCaseID, $iRescolumn, $sCusMsg)	
	Local $bReproduceTestCase = Common_ReproduceRunWithIni($sPrintFunctionName,$TestCaseID)
	If $bReproduceTestCase = False Then
		Return 3   
	EndIf	
	Local $sTestCaseLevel = Common_GetTestCaseLevel($oExcel, $TestCaseID,$sPrintFunctionName,$iCurrentSheetTotalLineNumber)   
	Local $bExecuteTestCase = Common_IsTestCaseLevelQualified($sTestCaseLevel)
	If $bExecuteTestCase = False Then
		Return 2   
	EndIf 
	Local $sCaptureImage = $TestCaseID & '.jpg'  
	Common_Del_DB() 
	Common_InitializeStatus()   
	InitializeStatusForPrint()
	FileCopy($sSampleFolderPath & '3.jpg', $sFunctionFolderPath, 1)
	Local $hPMHandle = Common_Run_PageManager_Ex($TestCaseID, $sTreeViewFunctionName)
	Common_SwitchToFolderInRootDiskC($hPMHandle, $sSectionNamePrint)
	Local $hThumbnailView = ControlGetHandle($hPMHandle, "", $sThumbnailViewCtrInfo)
	Common_SleepTime(1)	
	_GUICtrlListView_ClickItem($hThumbnailView, 0, "left") 
	Common_SleepTime(1)	
	ControlClick($hPMHandle, "", $sPageViewButtonInToolbarCtrInfo)
	Common_SleepTime(10)	
	If $bPageViewType	Then
		Send("^p")   ;Send ctrl + p to print.
	Else
		SelectPrint() 
	EndIf
	Common_SleepTime(2)	
	PrintFile($sTestResultPath & $TestCaseID)
	Local $bCompareFile = Common_CompareFile($sTestResultPath & $TestCaseID & '.tif', $sCorrectResultPath & $TestCaseID & '.tif')  			
	If $bCompareFile Then	
		Common_WriteLog($sPass, $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
		Common_Close_PM($hPMHandle) 
		Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
		Return 1   
	EndIf
	Common_WriteLog($sFaile & $sFailLogMsg , $TestCaseID,$sPrintFunctionName,$bReproduceTestCase)  
	Common_Close_PM($hPMHandle) 
	Common_WiteTestCaseExecuteRecode($sTempTXTPath,$TestCaseID)
	Return 0 
EndFunc
